from .celery import app as celery_app

__all__ = ('celery_app',)

# 应用统一的Celery修复方案，解决PicklingError和unpack错误
try:
    import sys
    import os
    # 确保能找到修复模块
    sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
    import celery_unified_fix
    # 修复会在模块导入时自动应用
    print("✅ 已导入统一的Celery修复模块")
except Exception as e:
    print(f"⚠️ 导入统一的Celery修复模块时出错: {str(e)}")
    # 避免在导入时抛出异常
    pass
